const path = require("path");

module.exports = {
  mode: "development",
  entry: path.resolve(__dirname, "example", "index.js"),
  output: {
    filename: "main.js",
    path: path.resolve(__dirname, "dist")
  },
  module: {
    rules: [
      {
        test: /\.(js|jsx)?$/,
        use: ["babel-loader"]
      }
    ]
  },
  resolve: {
    extensions: [".js", ".jsx", ".json"]
  },
  devServer: {
    contentBase: path.resolve(__dirname, "example"),
    port: 8080
  }
};
